import torch

# x = torch.arange(4)
# 具体的2*2张量
x = torch.tensor([[1, 2, 3], [4, 5, 6], [7, 8, 9]])
print(x)
# print(x[3])
print(f'张量的长度:{len(x)}')
print(f'张量的形状：{x.shape}')
print(f'张量的维度:{len(x.shape)}')
